#include <stdio.h>
#include <string.h>

/*
指针数组
*/
void point_array()
{
    int num1 = 100;
    int num2 = 200;
    int num3 = 300;
    int num4 = 400;
    int num5 = 500;

    int *arr[] = {&num1, &num2, &num3, &num4, &num5};

    for (int i = 0; i < 5; i++)
    {
        printf("%p->%d\n", arr[i], *arr[i]);
    }
}

void byte_point()
{
    char str1[100] = "welcome ";
    char str2[100] = "to beijing";
    char *p_str1[2] = {str1, str2};
    for (int i = 0; i < 2; i++)
    {
        printf("%s\n", *(p_str1 + i));
    }
}

int main(int argc, char const *argv[])
{
#if 0
    point_array();
#endif
    byte_point();
    /* code */
    return 0;
}
